/**
 * 桌面牌单张
 */
class TabelCard extends eui.Component {
	public card: eui.Image;
	public light: eui.Image;

	public constructor() {
		super();
	}
	public childrenCreated(): void {

	}

	public setData(value: number): void {
		this.card.source = "mj_card_" + value + "_png";
		this.light.visible = true;
		var self = this;
		var action = function () {
			egret.Tween.get(self.light).to({ y: -70 }, 600).to({ y: -40 }, 600).call(action, self);
		}
		action();
	}

	public hideLight(): void {
		this.light.visible = false;
		egret.Tween.removeTweens(this.light);
	}
}